package common

import (
	"context"
	"mini-app/internal/app/grpc/client"
	"mini-app/internal/app/grpc/protoc/system_admin"
)

// UserName 用户名称
func (GRPC) UserName(ctx context.Context, userIDs []string) *system_admin.UserNameRsp {
	cli, err := client.GetSystemAdminClient()
	if cli != nil && err == nil {
		rsp, err := cli.UserName(ctx, &system_admin.UserNameReq{
			UserIds: userIDs,
		})
		if rsp != nil && err == nil {
			return rsp
		}
	}
	return nil
}
